package models

import "time"

var MiniProgramContractStatus map[int]string

// 小程序纯签约记录
type MiniProgramContract struct {
	Id           int64     `orm:"description(自增主键)"`
	ContractCode string    `orm:"description(签约协议号)"`
	User         *User     `orm:"rel(fk);null;default(0);description(会员id)"`
	Status       int       `orm:"description(签约状态，0未知 1成功 2失败)"`
	StatusShow   string    `orm:"-"`
	FailMsg      string    `orm:"description(签约失败信息)"`
	Created      time.Time `orm:"auto_now_add;type(datetime);description(创建时间)"`
	CreatedShow  string    `orm:"-"`
}

func init() {
	MiniProgramContractStatus = map[int]string{
		0: "未知",
		1: "签约成功",
		2: "签约失败",
	}
}
